package com.example.datedemo2.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

@ApiModel("周类")
@TableName("week_sample")
public class WeekSample{
    // 主键
    private int projectId;

    @ApiModelProperty(value = "weekId", required = true)
    @TableId(type = IdType.ASSIGN_UUID)
    private String weekId;

    @ApiModelProperty(value = "周份", dataType = "String", example = "2022-12 2")
    @DateTimeFormat(pattern = "yyyy-MM W")
    @JsonFormat(pattern = "yyyy-MM W", timezone = "GMT+8")
    private Date weekNumber;

    @ApiModelProperty(value = "内容", example = "预留的int字段")
    private int weekText;

    public int getProjectId() {
        return projectId;
    }

    public void setProjectId(int projectId) {
        this.projectId = projectId;
    }

    public String getWeekId() {
        return weekId;
    }

    public void setWeekId(String weekId) {
        this.weekId = weekId;
    }

    public Date getWeekNumber() {
        return weekNumber;
    }

    public void setWeekNumber(Date weekNumber) {
        this.weekNumber = weekNumber;
    }

    public int getWeekText() {
        return weekText;
    }

    public void setWeekText(int weekText) {
        this.weekText = weekText;
    }
}
